#ifndef CLICKABLEAREA_H
#define CLICKABLEAREA_H

#include <SFML/Graphics.hpp>


class ClickableArea: public sf::Drawable
{
    public:
        ClickableArea(const sf::Vector2i& upperLeft, const sf::Vector2i& bottomRight);
        virtual ~ClickableArea();
        const sf::Vector2i& getUpperLeft() const;
        const sf::Vector2i& getBottomRight() const;
        void setUpperLeft(const sf::Vector2i&);
        void setBottomRight(const sf::Vector2i&);
        bool processMouseEvent(const sf::Vector2i& , sf::RenderWindow& window);

    protected:
		sf::Texture texture;
		sf::Sprite sprite;

    private:
        sf::Vector2i upperLeft;
        sf::Vector2i bottomRight;

		void draw(sf::RenderTarget& target, sf::RenderStates states) const;
		virtual void onClick( sf::RenderWindow& window ) = 0;
};

#endif // CLICKABLEAREA_H


